#include <algorithm>
#include <iostream>

using namespace std;

int helper( int p, bool lastIsBoy )
{
  if( p == 0 )
  {
    return 1;
  }
  int result = 0;
  if( lastIsBoy )
  {
    result += helper( p - 1, false );
  }
  result += helper( p - 1, true );
  return result;
}

int solution( int p )
{
  return helper( p, false ) + helper( p, true );
}

int main(int argc, char const *argv[])
{
  cout << solution( 30 ) << endl;
  return 0;
}
